#ifndef __CoreBase__h__included__
#define __CoreBase__h__included__

#include "Core.h"
#include <string>

namespace neiderra {
	namespace gui{
		namespace events
		{ 
			struct aEvent; 
		}
	}

	using gui::events::aEvent;

	namespace core {

        class iObject
        {
        public:
            iObject();
            virtual ~iObject(){}

            virtual const char* toString() { return "iObject"; }
        };

		class Base: public iObject
		{
		public:
			Base(Core* core_){core = core_;}
			virtual ~Base(){}

			// Associates core with object
			void setCore(Core* core_) { core = core_; }
            // Return core, associated with object
			Core* getCore() {return core;}

			virtual void response(aEvent* event){}

			// Converts object information into ANSI-string
			virtual const char* toString() { return "Base"; }

		protected:
			Core* core;
		};

		class iAlive: public Base {
		public:
			iAlive(Core* core): Base(core) {}
			virtual ~iAlive() {}
			virtual void update(double deltaT) {};
		};
	}
}

#endif
